package io.github.lee.app.unsplash.repository.api

import io.github.lee.app.unsplash.repository.domain.PageResponse
import io.github.lee.app.unsplash.repository.domain.Photo
import io.github.lee.app.unsplash.repository.domain.UnsplashResponse
import retrofit2.http.GET
import retrofit2.http.Query

interface SearchApi {

    @GET("search/photos")
    suspend fun searchPhoto(
        @Query("query") keyword: String,
        @Query("page") page: Int,
        @Query("per_page") size: Int,
        @Query("order_by") orderBy: String? = null,
        @Query("orientation") orientation: String? = null,
        @Query("color") color: String? = null
    ): UnsplashResponse<PageResponse<Photo>>
}